<template>
  <a-modal :title="title" :visible="visible" @ok="visible = false" width="1000px" @cancel="cancel">
    <slot></slot>
  </a-modal>
</template>

<script>
export default {
  props: {
    title: {
      type: String,
      default: ''
    }
  },

  data() {
    return {
      visible: false
    }
  },

  methods: {
    ok() {
      this.$emit('ok')
    },

    cancel() {
      this.visible = false
      this.$emit('cancel')
    }
  }
}
</script>

<style lang="less" scoped></style>
